﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.Mvc;
using System.Configuration;

namespace kxcxw.Data.Common
{
    /// <summary>
    /// 常量类
    /// </summary>
    public sealed class DataConstants
    {
        /// <summary>
        /// 促销方式ID
        /// </summary>
        public static string PromotionTypeItemID = ConfigurationManager.AppSettings["PromotionTypeItemID"];

        /// <summary>
        /// 产品类别ID
        /// </summary>
        public static string ProductTypeItemID = ConfigurationManager.AppSettings["ProductTypeItemID"];

        /// <summary>
        /// 用户类别
        /// </summary>
        public static string UserTypeItemID = ConfigurationManager.AppSettings["UserTypeItemID"];

        /// <summary>
        /// 公告类别
        /// </summary>
        public static string AnnouncementTypeItemID = ConfigurationManager.AppSettings["AnnouncementTypeItemID"];

        /// <summary>
        /// 来源网站
        /// </summary>
        public static string SourceTypeItemID = ConfigurationManager.AppSettings["SourceTypeItemID"];

        /// <summary>
        /// 推荐类别
        /// </summary>
        public static string AreaTypeItemID = ConfigurationManager.AppSettings["AreaTypeItemID"];

        public static string JinPingItemID = ConfigurationManager.AppSettings["JinPingItemID"];

        public static string TeSheItemID = ConfigurationManager.AppSettings["TeSheItemID"];

        /// <summary>
        /// 网店
        /// </summary>
        public const int WebShop = 1;

        /// <summary>
        /// 实体店
        /// </summary>
        public const int EntityShop = 2;

        #region 首页模块
        /// <summary>
        /// 限时抢购
        /// </summary>
        public static string PanicBuying = ConfigurationManager.AppSettings["PanicBuying"];

        /// <summary>
        /// 超低折扣
        /// </summary>
        public static string Discount = ConfigurationManager.AppSettings["Discount"];

        /// <summary>
        /// 降价处理
        /// </summary>
        public static string PriceReduction = ConfigurationManager.AppSettings["PriceReduction"];

        /// <summary>
        /// 购赠
        /// </summary>
        public static string BuyAdd = ConfigurationManager.AppSettings["BuyAdd"];

        /// <summary>
        /// 清仓处理
        /// </summary>
        public static string Clearance = ConfigurationManager.AppSettings["Clearance"];
        #endregion

        #region 权限相关
        public const string Admin = "管理员";

        public const string Member = "普通用户";
        #endregion


        #region 图片相关
        /// <summary>
        /// 列表页默认展示图片地址
        /// </summary>
        public static readonly string DefaultShowPicUrl = @"~/Content/upload/product_imgs/product_01.jpg";
        #endregion

        #region 系统设制
        /// <summary>
        /// 最多可以设制精品和特色的数量
        /// </summary>
        public const int MaxSpecialNum = 5;

        /// <summary>
        /// 默认过期天数
        /// </summary>
        public const int ExpirationDay = 180;

        public const int morePageSize = 32;
        #endregion

        #region 信息状态
        /// <summary>
        /// 未通过审核
        /// </summary>
        public const int pending = 0;
        /// <summary>
        /// 正常
        /// </summary>
        public const int Normal = 1;
        /// <summary>
        /// 删除
        /// </summary>
        public const int Deleted = 2;
        /// <summary>
        /// 违规
        /// </summary>
        public const int Illegal = 3;
        #endregion
    }
}
